import { reactive } from 'vue';

const state = reactive<{
  /**
   * 当前页
   */
  activePage: number;
  /**
   * 加载状态
   */
  loading: boolean;
  /**
   * 加载完成状态
   */
  finished: boolean;
  /**
   * 列表
   */
  list: ParkCar.Dto[];
  /**
   * 用户id
   */
  uaaUserId: string;
}>({
  activePage: 1,
  loading: false,
  finished: false,
  list: [],
  uaaUserId: '',
});

/**
 * 查询停车库剩余车位数
 */
const countState = reactive<{ spaceCountDto: SpaceCount.Dto[] }>({
  spaceCountDto: [],
});

export { state, countState };
